<extend name="Public/base"/>
<block name="content">
	<h3>广告位管理</h3>	
	<div class="panel panel-default">
		<div class="panel-heading"><if condition="$_GET['_action'] eq 'add'">新增<else/>编辑</if>广告位</div>
	 	<div class="panel-body">
			<!-- 表单 -->
			<form id="form" action="<{:addons_url('Ads://Ads/updateseat')}>" method="post" class="form-horizontal">
				<!-- 基础文档模型 -->
				<div id="tab1" class="tab-pane in tab1">
					<div class="form-group">
						<label class="col-sm-2 control-label">位置名称</label>
						<div class="col-sm-3">
							<input type="text" class="text form-control" name="title" value="<{$info.title}>">
						</div>
						<span class="check-tips">请输入广告显示的位置</span>
					</div>
					
					<div class="form-group">
						<label class="col-sm-2 control-label">位置标识</label>
						<div class="col-sm-3">
							<input type="text" class="text form-control" name="mark" value="<{$info.mark}>">
						</div>
						<span class="check-tips">只能为英文，调用的时候参数</span>
					</div>
					<div class="form-group">
						<label class="col-sm-2 control-label">广告类型</label>
						<div class="col-sm-3">
				            <!--label class="radio inline"><input type="radio" value="1" <eq name="info['type']" value="1">checked</eq> name="type">单图</label>
				            <label class="radio inline"><input type="radio" value="2" <eq name="info['type']" value="2">checked</eq> name="type">多图</label>
				            <label class="radio inline"><input type="radio" value="3" <eq name="info['type']" value="3">checked</eq> name="type">文字</label-->
				            <label class="radio inline"><input type="radio" value="4" <eq name="info['type']" value="4">checked</eq> <if condition="$_GET['_action'] eq 'addseat'">checked</if> name="type">代码</label>
						</div>
						<span class="check-tips">请选择广告类型，默认为单图</span>
					</div>
					<div class="form-group">
						<label class="col-sm-2 control-label">广告位宽度</label>
						<div class="col-sm-2">
							<input type="text" class="text form-control" name="width" value="<{$info.width}>">
						</div>
						<span class="check-tips">广告在前端展示的宽度</span>
					</div>
					<div class="form-group">
						<label class="col-sm-2 control-label">广告位高度</label>
						<div class="col-sm-2">
							<input type="text" class="text form-control" name="height" value="<{$info.height}>">
						</div>
						<span class="check-tips">广告在前端展示的高度</span>
					</div>
				</div>
				<input type="hidden" name="id" value="<{$info.id}>"/>
				<div class="form-group">
					<div class="col-sm-4 col-sm-offset-2">
						<button class="btn submit-btn ajax-post" id="submit" type="submit" target-form="form-horizontal">确 定</button>
						<input class="btn btn-return" type="reset" value="重置" />
					</div>
				</div>
			</form>
		</div>
	</div>
</block>

<block name="script">
<script type="text/javascript">
$(function(){
	$('#submit').click(function(){
		$('#form').submit();
	});
});
</script>
</block>